import { useDispatch, useSelector } from 'react-redux';
import type { RootState, AppDispatch } from '@/store';


// 在整个应用中使用useAppDispatch、useAppSelector，而不是普通的useDispatch和useSelector
export const useAppDispatch = useDispatch.withTypes<AppDispatch>();

export const useAppSelector = useSelector.withTypes<RootState>();
